export default function DeepCopy(newObj, oldObj) {
    for (let i in oldObj) {
        if (oldObj[i] instanceof Array) {
            newObj[i] = [];
            DeepCopy(newObj[i], oldObj[i])
        } else if (oldObj[i] instanceof Object) {
            newObj[i] = {};
            DeepCopy(newObj[i], oldObj[i])
        } else {
            newObj[i] = oldObj[i];
        }
    }
    return newObj;
}